package com.lantian.uavmaterial.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.lantian.uavmaterial.mapper.UavBatterySystemMapper;
import com.lantian.uavmaterial.domain.UavBatterySystem;
import com.lantian.uavmaterial.service.IUavBatterySystemService;

/**
 * 无人机电池Service业务层处理
 * 
 * @author lantian
 * @date 2025-11-06
 */
@Service
public class UavBatterySystemServiceImpl implements IUavBatterySystemService 
{
    @Autowired
    private UavBatterySystemMapper uavBatterySystemMapper;

    /**
     * 查询无人机电池
     * 
     * @param uavBatteryId 无人机电池主键
     * @return 无人机电池
     */
    @Override
    public UavBatterySystem selectUavBatterySystemByUavBatteryId(String uavBatteryId)
    {
        return uavBatterySystemMapper.selectUavBatterySystemByUavBatteryId(uavBatteryId);
    }

    /**
     * 查询无人机电池列表
     * 
     * @param uavBatterySystem 无人机电池
     * @return 无人机电池
     */
    @Override
    public List<UavBatterySystem> selectUavBatterySystemList(UavBatterySystem uavBatterySystem)
    {
        return uavBatterySystemMapper.selectUavBatterySystemList(uavBatterySystem);
    }

    /**
     * 新增无人机电池
     * 
     * @param uavBatterySystem 无人机电池
     * @return 结果
     */
    @Override
    public int insertUavBatterySystem(UavBatterySystem uavBatterySystem)
    {
        return uavBatterySystemMapper.insertUavBatterySystem(uavBatterySystem);
    }

    /**
     * 修改无人机电池
     * 
     * @param uavBatterySystem 无人机电池
     * @return 结果
     */
    @Override
    public int updateUavBatterySystem(UavBatterySystem uavBatterySystem)
    {
        return uavBatterySystemMapper.updateUavBatterySystem(uavBatterySystem);
    }

    /**
     * 批量删除无人机电池
     * 
     * @param uavBatteryIds 需要删除的无人机电池主键
     * @return 结果
     */
    @Override
    public int deleteUavBatterySystemByUavBatteryIds(String[] uavBatteryIds)
    {
        return uavBatterySystemMapper.deleteUavBatterySystemByUavBatteryIds(uavBatteryIds);
    }

    /**
     * 删除无人机电池信息
     * 
     * @param uavBatteryId 无人机电池主键
     * @return 结果
     */
    @Override
    public int deleteUavBatterySystemByUavBatteryId(String uavBatteryId)
    {
        return uavBatterySystemMapper.deleteUavBatterySystemByUavBatteryId(uavBatteryId);
    }


    /**
     * 根据无人机id查询无人机电池信息
     *
     * @param uavId 无人机id
     * @return 结果
     */
    @Override
    public UavBatterySystem selectUavBatterySystemByUavId(String uavId)
    {
        return uavBatterySystemMapper.selectUavBatterySystemByUavId(uavId);
    }



}
